<%--
  Created by IntelliJ IDEA.
  User: xiaoji
  Date: 2014/11/14
  Time: 15:52
  To change this template use File | Settings | File Templates.
--%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<%@ page contentType="text/html;charset=UTF-8" language="java"  pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%@ taglib prefix="spring" uri="/WEB-INF/lib/spring.tld"%>
<c:set value="${pageContext.request.contextPath}" var="path" scope="page"/>
<script src="${path}/js/jquery.min.js" type="text/javascript"></script>
<html>
<head>
    <title><spring:message code='help.list.title' /></title>
    <script type="text/javascript">

        $(function(){
            $(".toContent").click(function(){
                $.post("${path}/help/helpContent.html",{
                    id:$(this).attr("helpid")
                },function(data){
                    if(data !=null){
                        $("#content").html(data.content.context);
                    }
                },"");
            });

            $("#toContent0").trigger("click");
        });
    </script>
</head>
<body>
<spring:message code='help.list.msg1' /><br/>
<c:forEach items="${list}" var="l" varStatus="t">
    <div class="toContent" id="toContent${t.index}" helpid = "${l.id}" >${l.title}</div>
</c:forEach>
<spring:message code='help.list.msg2' /><br/>
<div id="content"></div>
</body>
</html>
